export default {
  form_nc2ods_wizard: {
    _odoo_model: 'ir.ui.view',
    model: 'fp.nc2ods.wizard',
    type: 'form',

    arch: {
      buttons: [
        {
          name: 'create_ods_order',
          string: '创建NC原始单据',
          type: 'object',
          btn_type: 'primary'
        }
      ]
    },

    fields: {
      nc_order_ids: {
        string: 'NC导入数据',
        widget: 'x2many_tree',
        readonly2: 1,
        views: {
          tree: {
            fields: {
              state: {},
              name: {},
              company_code: {},
              company_name: {},
              partner_code: {},
              partner_name: {},
              amount_total: {},
              note: {}
            }
          },
          form: {
            fields: {
              state: {},
              name: {},
              company_code: {},
              company_name: {},
              partner_code: {},
              partner_name: {},
              amount_total: {},
              note: {}
            }
          }
        }
      }
    }
  },

  action_nc_to_ods: {
    // 因为自动 从 nc 2 ods
    // 暂时 没有用
    _odoo_model: 'ir.actions',
    name: 'NC to ods',
    type: 'ir.actions.act_window',
    res_model: 'fp.nc2ods.wizard',
    domain: [],
    context: {
      active_model: 'fp.nc.ods.sale.order'
    },
    views: {
      form: 'form_nc2ods_wizard'
    }
  }
}
